home *** CD-ROM | disk | FTP | other *** search
/ NeXTSTEP 3.3 (Developer)…68k, x86, SPARC, PA-RISC] / NeXTSTEP 3.3 Dev Intel.iso / NextDeveloper / Headers / appkit / ClientInputManager.h < prev    next >
Text File  |  1992-02-21  |  3KB  |  122 lines

  1. /*
  2.     ClientInputManager.h
  3.     Application Kit, Release 2.1J
  4.       Copyright 1990, 1991 Canon, Inc.
  5. */
  6.  
  7. #ifdef KANJI
  8.  
  9. #import <objc/Object.h>
  10. #import <dpsclient/dpsclient.h>
  11.  
  12. //    mouse-click-part
  13. #define FRONTHALF        0x0
  14. #define BACKHALF        0x1
  15.  
  16. //    input-support-level
  17. #define IM_NOSUPPORT            0x0
  18. #define IM_WINDOWINPUT            0x1
  19. #define IM_INLINEINPUT            0x2
  20. #define IM_COLORINLINEINPUT        0x3
  21.  
  22. #define IM_COLOREDINLINEINPUT        0x3    // for backward compatibility
  23.  
  24. //    character-attribute
  25. #define    IM_NOATTRIBUTE    0x0
  26. #define    IM_UNDERLINE        0x1
  27. #define    IM_HIGHLIGHT        0x2
  28.  
  29. //    Default database parameter for port name used to communicate with an 
  30. //    input manager
  31. #define IM_PORTNAMEENTRY    "InputManager"
  32.  
  33. typedef struct _IMStartKey {
  34.     unsigned short    code;
  35.     int                flags;
  36. } IMStartKey;
  37.  
  38. @interface ClientInputManager:Object
  39. {
  40.     id                delegate;
  41.     char                *imPortName;
  42.  
  43.     id                _support; //     _IMIpcHandler
  44.     int                _ctxt;    //     contextNum
  45.     id                _responder;    //    first-responder
  46.     int                _displaySupportLevel;
  47.     
  48.     IMStartKey        *_startKeys;
  49.     int                _keyCount;
  50.     
  51.     int                _return_int;    
  52.     void                *_return_ptr;
  53.     
  54.     struct {
  55.         unsigned int        getCmdKey            :1;
  56.         unsigned int        imOn                :1;
  57.         unsigned int        autoConnect        :1;
  58.         unsigned int        _connectable        :1;
  59.         unsigned int        _connected            :1;
  60.         unsigned int        _displayDidCheck    :1;
  61.         unsigned int        _canDisplay        :1;
  62.         unsigned int        _setDeadKeyFlag    :1;
  63.     }                           _flags;
  64.  
  65.     int            _enableDeadKeys;
  66.     int            _count;
  67. }
  68.  
  69. - init;
  70. - (const char *)imPortName;
  71. - setIMPortName:(const char *)name;
  72. - free;
  73. - setDelegate:obj;
  74. - delegate;
  75. - setAutoConnect:(BOOL)flag;
  76. - imGetCommandKeyFirst:(BOOL)flag;
  77. - (int)imReturnINT;
  78. - imReturnID;
  79. - (BOOL)imReturnBOOL;
  80. - (const char *)imReturnSTR;
  81. - (void *)imReturnPTR;
  82.  
  83. - (int)imSendMessage: (SEL)selector, ...;
  84. - (int)imSendRecMessage: (SEL)selector, ...;
  85.  
  86. @end
  87.  
  88. @interface ClientInputManager(CimInterface)
  89.  
  90. - imBeginSession;
  91. - imEndSession;
  92. - imProcessEvent:(NXEvent *)anEvent from:sender;
  93.  
  94. - (int)imNotifyResponderWillChange;
  95. - (int)imNotifyResponderDidChange:(int)supportLevel;
  96. - (int)imNotifyActivated;
  97. - (int)imNotifyDeactivated;
  98.  
  99. - imAppDidBecomeActive;
  100. - imAppDidResignActive;
  101. - imKeyWindowWillChange:sender;
  102. - imKeyWindowDidChange:sender;
  103. - imFirstResponderWillChange:sender;
  104. - imFirstResponderDidChange:sender;
  105. - imTrapMouseAction:target;
  106.  
  107. - imCancelInput;
  108. - imSendInput;
  109. - imInsertionWillChange:sender;
  110. - imMouseDownAt:(int)pos :(int)part clickCount:(int)count keyState:(int)flag;
  111. - imMouseDraggedAt:(int)pos :(int)part keyState:(int)flag;
  112. - imMouseUpAt:(int)pos :(int)part clickCount:(int)count keyState:(int)flag;
  113. - (BOOL)imIsCommunicating;
  114. - (const char *)imCurrentInputMode;
  115. - (const char *)imName;
  116. - (const char *)imVersion;
  117. - imResponderDidFree:sender;
  118.  
  119. @end
  120.  
  121. #endif
  122.